<?php

namespace App\Models;

class PrizeRecord extends Model
{
    protected $fillable = [
        'prize_id', 'user_id', 'redeem_code', 'redeemflag', 'redeem_at','filiale_id', 'sendsmsflag', 'sendsms_at', 'remark'
    ];

    public function user()
    {
        return $this->belongsTo(User::class, 'user_id');
    }

    public function filiale()
    {
        return $this->belongsTo(Filiale::class, 'filiale_id');
    }

    public function prize()
    {
        return $this->belongsTo(Prize::class, 'prize_id');
    }

}
